package com.ieheima.mycharstream;

import java.io.FileWriter;
import java.io.IOException;

public class Demo1 {
    public static void main(String[] args) throws IOException {
        FileWriter fw = new FileWriter("day13_字符流&properties\\a.txt");

        fw.write('我');
        fw.write(System.lineSeparator());

        char[] chs = {'爱','吃','大','米'};
        fw.write(chs);
        fw.write(System.lineSeparator());

        fw.write(chs,2,2);
        fw.write(System.lineSeparator());

        fw.write("老鼠爱大米");
        fw.write(System.lineSeparator());
        fw.write("老鼠爱大米",0,2);

        fw.close();
    }
}
